package com.sxjh.entity.param;

import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.sxjh.entity.PageEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;
import java.util.LinkedHashSet;
import java.util.List;

@Data
@EqualsAndHashCode(callSuper = false)
public class ReportsDetailParam extends PageEntity {
    @ApiModelProperty("id")
    private Integer id;

    @ApiModelProperty(value = "装货地id")
    private Integer locationUpId;

    @ApiModelProperty(value = "装货点所属工厂id")
    private Integer locationUpFactoryId;

    @ApiModelProperty(value = "装货点所属车间id")
    private Integer locationUpWorkshopId;

    @ApiModelProperty(value = "卸货地id")
    private Integer locationDownId;

    @ApiModelProperty(value = "卸货点所属工厂id")
    private Integer locationDownFactoryId;

    @ApiModelProperty(value = "卸货点所属车间id")
    private Integer locationDownWorkshopId;

    @ApiModelProperty(value = "物料ID")
    private Integer materialId;

    @ApiModelProperty("时间方式:1.初磅时间, 2.复磅时间")
    private Integer type;

    @ApiModelProperty(value = "开始时间")
    private LocalDateTime createdAt;

    @ApiModelProperty(value = "结束时间")
    private LocalDateTime endAt;

    @ApiModelProperty("排序类型：1.派车单号, 2.初磅时间, 3.二次磅时间, 4.车牌号码, 5.物料名称, 6.毛重, 7.皮重, 8.净重, 9.装车点," +
            " 10.卸车点, 11.地磅单号, 12.装车点所属工厂, 13.装车点所属车间, 14.卸车点所属工厂, 15.卸车点所属车间")
    private Integer sortType;

    @ApiModelProperty("升降序类型：1.升序， 2.倒序")
    private Integer orderType;

    @ApiModelProperty("序号")
    @ExcelProperty(value = "序号")
    @ColumnWidth(10)
    private String index;

    @ApiModelProperty(value = "派车单号")
    @ExcelProperty(value = "派车单号")
    @ColumnWidth(30)
    private String orderNo;

    @ApiModelProperty("地磅单编号")
    @ExcelProperty(value = "地磅单编号")
    @ColumnWidth(20)
    private String number;

    @ApiModelProperty(value = "初磅时间")
    @ExcelProperty(value = "初磅时间")
    @ColumnWidth(45)
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private String tareAt;

    @ApiModelProperty(value = "重磅时间")
    @ExcelProperty(value = "重磅时间")
    @ColumnWidth(45)
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private String grossAt;

    @ApiModelProperty(value = "装货地名称")
    @ExcelProperty(value = "装车点")
    @ColumnWidth(45)
    private String locationUpName;

    @ApiModelProperty(value = "卸货地名称")
    @ExcelProperty(value = "卸车点")
    @ColumnWidth(45)
    private String locationDownName;

    @ApiModelProperty(value = "装货点所属工厂名称")
    @ExcelProperty(value = "装车点所属工厂")
    @ColumnWidth(45)
    private String locationUpFactoryName;

    @ApiModelProperty(value = "装货点所属车间名称")
    @ExcelProperty(value = "装车点所属车间")
    @ColumnWidth(45)
    private String locationUpWorkshopName;

    @ApiModelProperty(value = "卸货点所属工厂名称")
    @ExcelProperty(value = "卸车点所属车间")
    @ColumnWidth(45)
    private String locationDownFactoryName;

    @ApiModelProperty(value = "卸货点所属车间名称")
    @ExcelProperty(value = "卸车点所属车间")
    @ColumnWidth(45)
    private String locationDownWorkshopName;

    @ApiModelProperty(value = "车数")
    private Integer vehNumberCount;

    @ApiModelProperty("车号")
    @ExcelProperty(value = "车牌号码")
    private String vehNumber;

    @ApiModelProperty("物料名称")
    @ExcelProperty(value = "物料名称")
    @ColumnWidth(45)
    private String materialName;

    @ApiModelProperty(value = "毛重数")
    @ExcelProperty(value = "毛重/吨")
    @ColumnWidth(30)
    private Double grossCount;

    @ApiModelProperty(value = "皮重数")
    @ExcelProperty(value = "皮重/吨")
    @ColumnWidth(30)
    private Double tareCount;

    @ApiModelProperty(value = "净重数")
    @ExcelProperty(value = "净重/吨")
    @ColumnWidth(30)
    private Double netCount;

    @ApiModelProperty(value = "计划单no")
    private String plannedOrderNo;

    @ApiModelProperty(value = "计划单id")
    private Integer plannedOrderId;

    @ApiModelProperty(value = "更新时间")
    private LocalDateTime updatedAt;

    @ApiModelProperty(value = "表头字段")
    private LinkedHashSet<String> headerFields;

    @ApiModelProperty(value = "导出标识：1.导出Excel，2.导出pdf")
    private Integer flag = 1;

    private List<Integer> plannedOrderIdList;

    private List<Integer> statusList;

}